<template>
    <div style="padding: 20px;">
      <div class="headerBoxList">
        <svg width="24" height="24" viewBox="0 0 48 48" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M18 25.9993V10C18 6.68629 20.6863 4 24 4C27.3137 4 30 6.68629 30 10V25.9993C32.4289 27.8237 34 30.7284 34 34C34 39.5228 29.5228 44 24 44C18.4772 44 14 39.5228 14 34C14 30.7284 15.5711 27.8237 18 25.9993Z" fill="none" stroke="#333" stroke-width="4" stroke-linejoin="round"/><path d="M24 17V30" stroke="#333" stroke-width="4" stroke-linecap="round" stroke-linejoin="round"/><path d="M24 38C26.2091 38 28 36.2091 28 34C28 31.7909 26.2091 30 24 30C21.7909 30 20 31.7909 20 34C20 36.2091 21.7909 38 24 38Z" fill="none" stroke="#333" stroke-width="4" stroke-linejoin="round"/></svg>
        <span style="margin-left: 10px">温度属性 <span style="font-size: 15px;" v-if="total!==0">({{ total }}行)</span></span>
        </div>
        <div class="content">
      
          <p style="border-bottom: 1px solid #ebebeb;" v-for="(item,index) in list" :key="index">· {{ item }}</p>
        </div>
    </div>
  </template>
  
  <script>
  export default {
      name:'temperature',
      data(){
          return{
              list:[],
              total:0
          }
      },
      mounted(){
          this.init();
      },
      methods:{
      init(){
          let str = `
kali:/ # dumpsys hardware_properties
****** Dump of HardwarePropertiesManagerService ******
Security exception: Package unknown does not belong to 0
kali:/ #



HWLON:/ $ dumpsys hardware_properties
****** Dump of HardwarePropertiesManagerService ******
CPU temperatures: [34.0, 35.0]
CPU throttling temperatures: [-3.4028235E38, -3.4028235E38]
CPU shutdown temperatures: [105.0, 105.0]
CPU vr throttling temperatures: [-3.4028235E38, -3.4028235E38]
GPU temperatures: [31.0]
GPU throttling temperatures: [-3.4028235E38]
GPU shutdown temperatures: [105.0]
GPU vr throttling temperatures: [-3.4028235E38]
Battery temperatures: [31.0]
Battery throttling temperatures: [-3.4028235E38]
Battery shutdown temperatures: [68.0]
Battery vr throttling temperatures: [-3.4028235E38]
Skin temperatures: [23.631]
Skin throttling temperatures: [53.0]
Skin shutdown temperatures: [55.0]
Skin vr throttling temperatures: [53.0]
Fan speed: []

Cpu usage of core: 0, active = 317644, total = 3548485
Cpu usage of core: 1, active = 289210, total = 289246
Cpu usage of core: 2, active = 245211, total = 245252
Cpu usage of core: 3, active = 223370, total = 223412
Cpu usage of core: 4, active = 106387, total = 106782
Cpu usage of core: 5, active = 64176, total = 64610
Cpu usage of core: 6, active = 56963, total = 57370
Cpu usage of core: 7, active = 53250, total = 53555
****** End of HardwarePropertiesManagerService dump ******
HWLON:/ $

`
          let arr = str.split("\n");
          this.list = arr;
          this.total = arr.length;
      }
  
      }
  
  }
  </script>
  
  <style scoped>
      .headerBoxList {
      width: 100%;
      height: 50px;
      border-bottom: 1px solid #d2d2d2;
      display: flex;
      align-items: center;
      font-size: 18px;
      font-weight: bold;
    }
    .content{
      height: 80vh;
      overflow-y: auto;
      padding-left:50px;
      margin-top: 20px;
  }
    @media screen and (min-width: 2360px) {
      .content{
      height:67vh;
      overflow-y: auto;
  
    }
    }
  </style>